package com.eastfair.imaster.entity;

import cn.afterturn.easypoi.excel.annotation.Excel;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.eastfair.annotation.model.EchoVO;
import com.eastfair.core.base.entity.Entity;
import com.eastfair.imaster.enumeration.ConferenceTopicSpeakerTypeEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;

import java.time.LocalDateTime;
import java.util.HashMap;
import java.util.Map;

/**
 * <p>
 * 实体类
 * 论坛主题嘉宾
 * </p>
 *
 * @author zjn
 * @since 2021-11-10
 */
@Data
@NoArgsConstructor
@ToString(callSuper = true)
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("o_conference_topic_speaker")
@ApiModel(value = "ConferenceTopicSpeaker", description = "论坛主题嘉宾")
@AllArgsConstructor
public class ConferenceTopicSpeaker extends Entity<Long> implements EchoVO {

    private static final long serialVersionUID = 1L;
    @TableField(exist = false)
    private Map<String, Object> echoMap = new HashMap<>();
    /**
     * 项目id
     */
    @ApiModelProperty(value = "项目id")
    @TableField(value = "project_id")
    @Excel(name = "项目id")
    private Long projectId;

    /**
     * 会议日程主题id
     */
    @ApiModelProperty(value = "会议日程主题id")
    @TableField(value = "conference_topic_id")
    @Excel(name = "会议日程主题id")
    private Long conferenceTopicId;

    /**
     * 嘉宾id
     */
    @ApiModelProperty(value = "嘉宾id")
    @TableField(value = "speaker_id")
    @Excel(name = "嘉宾id")
    private Long speakerId;

    /**
     * 类型 #{host:主持人;speaker:演讲者}
     */
    @ApiModelProperty(value = "类型 #{host:主持人;speaker:演讲者}")
    @TableField(value = "type")
    @Excel(name = "类型 #{host:主持人;speaker:演讲者}", replace = {"主持人_HOST", "演讲者_SPEAKER",  "_null"})
    private ConferenceTopicSpeakerTypeEnum type;

    /**
     * 排序
     */
    @ApiModelProperty(value = "排序")
    @TableField(value = "sequence")
    @Excel(name = "排序")
    private Integer sequence;

    /**
     * 是否启用：1是；0否
     */
    @ApiModelProperty(value = "是否启用：1是；0否")
    @TableField(value = "is_enabled")
    @Excel(name = "是否启用：1是；0否")
    private Integer isEnabled;

    /**
     * 是否删除：1是；0否
     */
    @ApiModelProperty(value = "是否删除：1是；0否")
    @TableField(value = "is_deleted")
    @Excel(name = "是否删除：1是；0否")
    private Integer isDeleted;


    @Builder
    public ConferenceTopicSpeaker(Long id, Long createdBy, LocalDateTime createTime, Long updatedBy, LocalDateTime updateTime, 
                    Long projectId, Long conferenceTopicId, Long speakerId, ConferenceTopicSpeakerTypeEnum type, Integer sequence, 
                    Integer isEnabled, Integer isDeleted) {
        this.id = id;
        this.createdBy = createdBy;
        this.createTime = createTime;
        this.updatedBy = updatedBy;
        this.updateTime = updateTime;
        this.projectId = projectId;
        this.conferenceTopicId = conferenceTopicId;
        this.speakerId = speakerId;
        this.type = type;
        this.sequence = sequence;
        this.isEnabled = isEnabled;
        this.isDeleted = isDeleted;
    }

}
